package cmdimpl

import (
	"lnzw/engine/args"
	"lnzw/server/logic/base"
	"lnzw/server/logic/cmd"
)

type CloseServer struct {
}

func init() {
	cmd.Register(&CloseServer{})
}

func (c *CloseServer) Id() cmd.CmdId {
	return CMD_ID_CLOSE_SERVER
}
func (c *CloseServer) Run(args *args.Args) error {
	if base.GlobalServer != nil {
		base.GlobalServer.Stop()
	}
	return nil
}
func (c *CloseServer) Desc() string {
	return "closeserver"
}
